package cn.botter.auth.common.enums;

import lombok.Getter;

@Getter
public enum IsDeletedEnum {
    DELETED(1 , "逻辑删除"),
    UN_DELETED(0,"没有标记删除");

    public int code;
    public String desc;

    IsDeletedEnum(int code , String desc){
        this.code = code;
        this.desc = desc;
    }

    public static IsDeletedEnum getByCode(int codeVal){
        for(IsDeletedEnum resultCodeEnum :  IsDeletedEnum.values()){
            if (resultCodeEnum.code == codeVal){
                return resultCodeEnum;
            }
        }
        return null;
    }
}
